<template>
  <div class="max">
    <my-header :backBtn="true"></my-header>
    <div class="cont-nof">
      <div class="weui-form-preview">
        <div class="weui-form-preview__hd">
          <div class="weui-form-preview__item">
            <label class="weui-form-preview__label">离园人</label>
            <em class="weui-form-preview__value">{{data.studentName}}</em>
          </div>
        </div>
        <div class="weui-form-preview__bd">
          <div class="weui-form-preview__item">
            <label class="weui-form-preview__label">离园时间</label>
            <span class="weui-form-preview__value">{{data.wantLeaveTime}}</span>
          </div>
          <div class="weui-form-preview__item">
            <label class="weui-form-preview__label">申请人</label>
            <span class="weui-form-preview__value">{{data.whoApply}}</span>
          </div>
          <div class="weui-form-preview__item">
            <label class="weui-form-preview__label">申请理由</label>
            <span class="weui-form-preview__value">{{data.reason}}</span>
          </div>
          <div class="weui-form-preview__item">
            <label class="weui-form-preview__label">申请时间</label>
            <span class="weui-form-preview__value">{{data.createTime}}</span>
          </div>
        </div>
      </div>
    </div>
  </div>
</template>

<script>
  export default {
    data() {
      return {
        data: {},
      }
    }, methods: {
      fetchOutLeaveApplyById(id){
        this.$http.fetchOutLeaveApplyById(id).then(resp=>{
          this.data=resp.data;
        })
      }
    },
    mounted(){
      this.fetchOutLeaveApplyById(this.$route.query.id);
    },
    created() {
    }
  }
</script>

<style scoped>
  .details-title {
    font-size: 1.8rem;
    width: 100%;
    padding: 0.5rem 0;
    background: #F7F7F7;
  }
</style>
